System and method for identifying complex tokens in an image

ABSTRACT

In a first exemplary embodiment of the present invention, an automated, computerized method is provided for processing an image. According to a feature of the present invention, the method comprises the steps of providing an image file depicting an image, in a computer memory, determining log chromaticity representations for the image, clustering the log chromaticity representations to provide clusters of similar log chromaticity representations and identifying regions of uniform reflectance in the image as a function of the clusters of similar log chromaticity representations.

BACKGROUND OF THE INVENTION

Many significant and commercially important uses of modern computertechnology relate to images. These include image processing, imageanalysis and computer vision applications. In computer visionapplications, such as, for example, object recognition and opticalcharacter recognition, it has been found that a separation ofillumination and material aspects of an image can significantly improvethe accuracy of computer performance.

SUMMARY OF THE INVENTION

The present invention provides a method and system comprising imagetechniques that accurately and correctly identify regions of an imagethat each correspond to a single material reflectance in a scenedepicted in the image.

In a first exemplary embodiment of the present invention, an automated,computerized method is provided for processing an image. According to afeature of the present invention, the method comprises the steps ofproviding an image file depicting an image, in a computer memory,determining log chromaticity representations for the image, clusteringthe log chromaticity representations to provide clusters of similar logchromaticity representations and identifying regions of uniformreflectance in the image as a function of the clusters of similar logchromaticity representations.

In a second exemplary embodiment of the present invention, a computersystem is provided. The computer system comprises a CPU and a memorystoring an image file containing an image. According to a feature of thepresent invention, the CPU is arranged and configured to execute aroutine to determine log chromaticity representations for the image,cluster the log chromaticity representations to provide clusters ofsimilar log chromaticity representations and identify regions of uniformreflectance in the image as a function of the clusters of similar logchromaticity representations.

In a third exemplary embodiment of the present invention, a computerprogram product, disposed on a computer readable media is provided. Thecomputer program product includes computer executable process stepsoperable to control a computer to: provide an image file depicting animage, in a computer memory, determine log chromaticity representationsfor the image, cluster the log chromaticity representations to provideclusters of similar log chromaticity representations and identifyregions of uniform reflectance in the image as a function of theclusters of similar log chromaticity representations.

In accordance with yet further embodiments of the present invention,computer systems are provided, which include one or more computersconfigured (e.g., programmed) to perform the methods described above. Inaccordance with other embodiments of the present invention,non-transitory computer readable media are provided which have storedthereon computer executable process steps operable to control acomputer(s) to implement the embodiments described above. The presentinvention contemplates a computer readable media as any product thatembodies information usable in a computer to execute the methods of thepresent invention, including instructions implemented as a hardwarecircuit, for example, as in an integrated circuit chip. The automated,computerized methods can be performed by a digital computer, analogcomputer, optical sensor, state machine, sequencer, integrated chip orany device or apparatus that can be designed or programmed to carry outthe steps of the methods of the present invention.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram of a computer system arranged and configuredto perform operations related to images.

FIG. 2 shows an n×m pixel array image file for an image stored in thecomputer system of FIG. 1.

FIG. 3 a is a flow chart for identifying Type C token regions in theimage file of FIG. 2, according to a feature of the present invention.

FIG. 3 b is an original image used as an example in the identificationof Type C tokens.

FIG. 3 c shows Type C token regions in the image of FIG. 3 b.

FIG. 3 d shows Type B tokens, generated from the Type C tokens of FIG. 3c, according to a feature of the present invention.

FIG. 4 is a flow chart for a routine to test Type C tokens identified bythe routine of the flow chart of FIG. 3 a, according to a feature of thepresent invention.

FIG. 5 is a graphic representation of a log color space chromaticityplane according to a feature of the present invention.

FIG. 6 is a flow chart for determining a list of colors depicted in aninput image.

FIG. 7 is a flow chart for determining an orientation for a logchromaticity space, according to a feature of the present invention.

FIG. 8 is a flow chart for determining log chromaticity coordinates forthe colors of an input image, as determined through execution of theroutine of FIG. 6, according to a feature of the present invention.

FIG. 9 is a flow chart for augmenting the log chromaticity coordinates,as determined through execution of the routine of FIG. 8, according to afeature of the present invention.

FIG. 10 is a flow chart for clustering the log chromaticity coordinates,according to a feature of the present invention.

FIG. 11 is a flow chart for assigning the log chromaticity coordinatesto clusters determined through execution of the routine of FIG. 10,according to a feature of the present invention.

FIG. 12 is a flow chart for detecting regions of uniform reflectancebased on the log chromaticity clustering according to a feature of thepresent invention.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

Referring now to the drawings, and initially to FIG. 1, there is shown ablock diagram of a computer system 10 arranged and configured to performoperations related to images. A CPU 12 is coupled to a device such as,for example, a digital camera 14 via, for example, a USB port. Thedigital camera 14 operates to download images stored locally on thecamera 14, to the CPU 12. The CPU 12 stores the downloaded images in amemory 16 as image files 18. The image files 18 can be accessed by theCPU 12 for display on a monitor 20, or for print out on a printer 22.

Alternatively, the CPU 12 can be implemented as a microprocessorembedded in a device such as, for example, the digital camera 14 or arobot. The CPU 12 can also be equipped with a real time operating systemfor real time operations related to images, in connection with, forexample, a robotic operation or an interactive operation with a user.

As shown in FIG. 2, each image file 18 comprises an n×m pixel array.Each pixel, p, is a picture element corresponding to a discrete portionof the overall image. All of the pixels together define the imagerepresented by the image file 18. Each pixel comprises a digital valuecorresponding to a set of color bands, for example, red, green and bluecolor components (RGB) of the picture element. The present invention isapplicable to any multi-band image, where each band corresponds to apiece of the electro-magnetic spectrum. The pixel array includes n rowsof m columns each, starting with the pixel p (1,1) and ending with thepixel p(n, m). When displaying or printing an image, the CPU 12retrieves the corresponding image file 18 from the memory 16, andoperates the monitor 20 or printer 22, as the case may be, as a functionof the digital values of the pixels in the image file 18, as isgenerally known.

In an image operation, the CPU 12 operates to analyze the RGB values ofthe pixels of a stored image file 18 to achieve various objectives, suchas, for example, to identify regions of an image that correspond to asingle material depicted in a scene recorded in the image file 18. Afundamental observation underlying a basic discovery of the presentinvention, is that an image comprises two components, material andillumination. All changes in an image are caused by one or the other ofthese components. A method for detecting of one of these components, forexample, material, provides a mechanism for distinguishing material orobject geometry, such as object edges, from illumination and shadowboundaries.

Such a mechanism enables techniques that can be used to generateintrinsic images. The intrinsic images correspond to an original image,for example, an image depicted in an input image file 18. The intrinsicimages include, for example, an illumination image, to capture theintensity and color of light incident upon each point on the surfacesdepicted in the image, and a material reflectance image, to capturereflectance properties of surfaces depicted in the image (the percentageof each wavelength of light a surface reflects). The separation ofillumination from material in the intrinsic images provides the CPU 12with images optimized for more effective and accurate furtherprocessing.

Pursuant to a feature of the present invention, a token is a connectedregion of an image wherein the pixels of the region are related to oneanother in a manner relevant to identification of image features andcharacteristics such as an identification of materials and illumination.The pixels of a token can be related in terms of either homogeneousfactors, such as, for example, close correlation of color among thepixels, or inhomogeneous factors, such as, for example, differing colorvalues related geometrically in a color space such as RGB space,commonly referred to as a texture. The present invention utilizesspatio-spectral information relevant to contiguous pixels of an imagedepicted in an image file 18 to identify token regions. Thespatio-spectral information includes spectral relationships amongcontiguous pixels, in terms of color bands, for example the RGB valuesof the pixels, and the spatial extent of the pixel spectralcharacteristics relevant to a single material.

According to one exemplary embodiment of the present invention, tokensare each classified as either a Type A token, a Type B token or a Type Ctoken. A Type A token is a connected image region comprising contiguouspixels that represent the largest possible region of the imageencompassing a single material in the scene (uniform reflectance). AType B token is a connected image region comprising contiguous pixelsthat represent a region of the image encompassing a single material inthe scene, though not necessarily the maximal region of uniformreflectance corresponding to that material. A Type B token can also bedefined as a collection of one or more image regions or pixels, all ofwhich have the same reflectance (material color) though not necessarilyall pixels which correspond to that material color. A Type C tokencomprises a connected image region of similar image properties among thecontiguous pixels of the token, where similarity is defined with respectto a noise model for the imaging system used to record the image.

Referring now to FIG. 3 a, there is shown a flow chart for identifyingType C token regions in the scene depicted in the image file 18 of FIG.2, according to a feature of the present invention. Type C tokens can bereadily identified in an image, utilizing the steps of FIG. 3 a, andthen analyzed and processed to construct Type B tokens, according to afeature of the present invention.

A 1^(st) order uniform, homogeneous Type C token comprises a singlerobust color measurement among contiguous pixels of the image. At thestart of the identification routine, the CPU 12 sets up a region map inmemory. In step 100, the CPU 12 clears the region map and assigns aregion ID, which is initially set at 1. An iteration for the routine,corresponding to a pixel number, is set at i=0, and a number for an N×Npixel array, for use as a seed to determine the token, is set an initialvalue, N=N_(start). N_(start) can be any integer>0, for example it canbe set at set at 11 or 15 pixels.

At step 102, a seed test is begun. The CPU 12 selects a first pixel,i=1, pixel (1, 1) for example (see FIG. 2), the pixel at the upper leftcorner of a first N×N sample of the image file 18. The pixel is thentested in decision block 104 to determine if the selected pixel is partof a good seed. The test can comprise a comparison of the color value ofthe selected pixel to the color values of a preselected number of itsneighboring pixels as the seed, for example, the N×N array. The colorvalues comparison can be with respect to multiple color band values (RGBin our example) of the pixel. If the comparison does not result inapproximately equal values (within the noise levels of the recordingdevice) for the pixels in the seed, the CPU 12 increments the value of i(step 106), for example, i=2, pixel (1, 2), for a next N×N seed sample,and then tests to determine if i=i_(max) (decision block 108).

If the pixel value is at i_(max), a value selected as a threshold fordeciding to reduce the seed size for improved results, the seed size, N,is reduced (step 110), for example, from N=15 to N=12. In an exemplaryembodiment of the present invention, i_(max) can be set at a number ofpixels in an image ending at pixel (n, m), as shown in FIG. 2. In thismanner, the routine of FIG. 3 a parses the entire image at a first valueof N before repeating the routine for a reduced value of N.

After reduction of the seed size, the routine returns to step 102, andcontinues to test for token seeds. An N_(stop) value (for example, N=2)is also checked in step 110 to determine if the analysis is complete. Ifthe value of N is at N_(stop), the CPU 12 has completed a survey of theimage pixel arrays and exits the routine.

If the value of i is less than i_(max), and N is greater than N_(stop),the routine returns to step 102, and continues to test for token seeds.

When a good seed (an N×N array with approximately equal pixel values) isfound (block 104), the token is grown from the seed. In step 112, theCPU 12 pushes the pixels from the seed onto a queue. All of the pixelsin the queue are marked with the current region ID in the region map.The CPU 12 then inquires as to whether the queue is empty (decisionblock 114). If the queue is not empty, the routine proceeds to step 116.

In step 116, the CPU 12 pops the front pixel off the queue and proceedsto step 118. In step 118, the CPU 12 marks “good” neighbors around thesubject pixel, that is neighbors approximately equal in color value tothe subject pixel, with the current region ID. All of the marked goodneighbors are placed in the region map and also pushed onto the queue.The CPU 12 then returns to the decision block 114. The routine of steps114, 116, 118 is repeated until the queue is empty. At that time, all ofthe pixels forming a token in the current region will have beenidentified and marked in the region map as a Type C token.

When the queue is empty, the CPU 12 proceeds to step 120. At step 120,the CPU 12 increments the region ID for use with identification of anext token. The CPU 12 then returns to step 106 to repeat the routine inrespect of the new current token region.

Upon arrival at N=N_(stop), step 110 of the flow chart of FIG. 3 a, orcompletion of a region map that coincides with the image, the routinewill have completed the token building task. FIG. 3 b is an originalimage used as an example in the identification of tokens. The imageshows areas of the color blue and the blue in shadow, and of the colorteal and the teal in shadow. FIG. 3 c shows token regions correspondingto the region map, for example, as identified through execution of theroutine of FIG. 3 a (Type C tokens), in respect to the image of FIG. 3b. The token regions are color coded to illustrate the token makeup ofthe image of FIG. 3 b, including penumbra regions between the full colorblue and teal areas of the image and the shadow of the colored areas.

While each Type C token comprises a region of the image having a singlerobust color measurement among contiguous pixels of the image, the tokenmay grow across material boundaries. Typically, different materialsconnect together in one Type C token via a neck region often located onshadow boundaries or in areas with varying illumination crossingdifferent materials with similar hue but different intensities. A neckpixel can be identified by examining characteristics of adjacent pixels.When a pixel has two contiguous pixels on opposite sides that are notwithin the corresponding token, and two contiguous pixels on oppositesides that are within the corresponding token, the pixel is defined as aneck pixel.

FIG. 4 shows a flow chart for a neck test for Type C tokens. In step122, the CPU 12 examines each pixel of an identified token to determinewhether any of the pixels under examination forms a neck. The routine ofFIG. 4 can be executed as a subroutine directly after a particular tokenis identified during execution of the routine of FIG. 3 a. All pixelsidentified as a neck are marked as “ungrowable.” In decision block 124,the CPU 12 determines if any of the pixels were marked.

If no, the CPU 12 exits the routine of FIG. 4 and returns to the routineof FIG. 3 a (step 126).

If yes, the CPU 12 proceeds to step 128 and operates to regrow the tokenfrom a seed location selected from among the unmarked pixels of thecurrent token, as per the routine of FIG. 3 a, without changing thecounts for seed size and region ID. During the regrowth process, the CPU12 does not include any pixel previously marked as ungrowable. After thetoken is regrown, the previously marked pixels are unmarked so thatother tokens may grow into them.

Subsequent to the regrowth of the token without the previously markedpixels, the CPU 12 returns to step 122 to test the newly regrown token.Neck testing identifies Type C tokens that cross material boundaries,and regrows the identified tokens to provide single material Type Ctokens suitable for use in creating Type B tokens.

FIG. 3 d shows Type B tokens generated from the Type C tokens of FIG. 3c, according to a feature of the present invention. The presentinvention provides a novel exemplary technique using log chromaticityclustering, for constructing Type B tokens for an image file 18. Logchromaticity is a technique for developing an illumination invariantchromaticity space.

A method and system for separating illumination and reflectance using alog chromaticity representation is disclosed in U.S. Pat. No. 7,596,266,which is hereby expressly incorporated by reference. The techniquestaught in U.S. Pat. No. 7,596,266 can be used to provide illuminationinvariant log chromaticity representation values for each color of animage, for example, as represented by Type C tokens. Logarithmic valuesof the color band values of the image pixels are plotted on a log-colorspace graph. The logarithmic values are then projected to alog-chromaticity projection plane oriented as a function of abi-illuminant dichromatic reflection model (BIDR model), to provide alog chromaticity value for each pixel, as taught in U.S. Pat. No.7,596,266. The BIDR Model predicts that differing color measurementvalues fall within a cylinder in RGB space, from a dark end (in shadow)to a bright end (lit end), along a positive slope, when the color changeis due to an illumination change forming a shadow over a single materialof a scene depicted in the image.

FIG. 5 is a graphic representation of a log color space, bi-illuminantchromaticity plane according to a feature of the invention disclosed inU.S. Pat. No. 7,596,266. The alignment of the chromaticity plane isdetermined by a vector N, normal to the chromaticity plane, and definedas N=log(Bright_(vector))−log(Dark_(vector))=log(1+1/S_(vector)). Theco-ordinates of the plane, u, v can be defined by a projection of thegreen axis onto the chromaticity plane as the u axis, and the crossproduct of u and N being defined as the v axis. In our example, each logvalue for the materials A, B, C is projected onto the chromaticityplane, and will therefore have a corresponding u, v co-ordinate value inthe plane that is a chromaticity value, as shown in FIG. 5.

Thus, according to the technique disclosed in U.S. Pat. No. 7,596,266,the RGB values of each pixel in an image file 18 can be mapped by theCPU 12 from the image file value p(n, m, R, G, B) to a log value, then,through a projection to the chromaticity plane, to the corresponding u,v value, as shown in FIG. 5. Each pixel p(n, m, R, G, B) in the imagefile 18 is then replaced by the CPU 12 by a two dimensional chromaticityvalue: p(n, m, u, v), to provide a chromaticity representation of theoriginal RGB image. In general, for an N band image, the N color valuesare replaced by N−1 chromaticity values. The chromaticity representationis a truly accurate illumination invariant representation because theBIDR model upon which the representation is based, accurately andcorrectly represents the illumination flux that caused the originalimage.

According to a feature of the present invention, log chromaticity valuesare calculated for each color depicted in an image file 18 input to theCPU 12 for identification of regions of the uniform reflectance (Type Btokens). For example, each pixel of a Type C token will be ofapproximately the same color value, for example, in terms of RGB values,as all the other constituent pixels of the same Type C token, within thenoise level of the equipment used to record the image. Thus, an averageof the color values for the constituent pixels of each particular Type Ctoken can be used to represent the color value for the respective Type Ctoken in the log chromaticity analysis.

FIG. 6 is a flow chart for determining a list of colors depicted in aninput image, for example, an image file 18. In step 200, an input imagefile 18 is input to the CPU 12 for processing. In steps 202 and 204, theCPU 12 determines the colors depicted in the input image file 18. Instep 202, the CPU 12 calculates an average color for each Type C tokendetermined by the CPU 12 through execution of the routine of FIG. 3 a,as described above, for a list of colors. The CPU 12 can be operated tooptionally require a minimum token size, in terms of the number ofconstituent pixels of the token, or a minimum seed size (the N×N array)used to determine Type C tokens according to the routine of FIG. 3 a,for the analysis. The minimum size requirements are implemented toassure that color measurements in the list of colors for the image arean accurate depiction of color in a scene depicted in the input image,and not an artifact of blend pixels.

Blend pixels are pixels between two differently colored regions of animage. If the colors between the two regions are plotted in RGB space,there is a linear transition between the colors, with each blend pixel,moving from one region to the next, being a weighted average of thecolors of the two regions. Thus, each blend pixel does not represent atrue color of the image. If blend pixels are present, relatively smallType C tokens, consisting of blend pixels, can be identified for areasof an image between two differently colored regions. By requiring a sizeminimum, the CPU 12 can eliminate tokens consisting of blend pixel fromthe analysis.

In step 204, the CPU 12 can alternatively collect colors at the pixellevel, that is, the RGB values of the pixels of the input image file 18,as shown in FIG. 2. The CPU 12 can be operated to optionally requireeach pixel of the image file 18 used in the analysis to have a minimumstability or local standard deviation via a filter output, for a moreaccurate list of colors. For example, second derivative energy can beused to indicate the stability of pixels of an image.

In this approach, the CPU 12 calculates a second derivative at eachpixel, or a subset of pixels disbursed across the image to cover allillumination conditions of the image depicted in an input image file 18,using a Difference of Gaussians, Laplacian of Gaussian, or similarfilter. The second derivative energy for each pixel examined can then becalculated by the CPU 12 as the average of the absolute value of thesecond derivative in each color band (or the absolute value of thesingle value in a grayscale image), the sum of squares of the values ofthe second derivatives in each color band (or the square of the singlevalue in a grayscale image), the maximum squared second derivative valueacross the color bands (or the square of the single value in a grayscaleimage), or any similar method. Upon the calculation of the secondderivative energy for each of the pixels, the CPU 12 analyzes the energyvalues of the pixels. There is an inverse relationship between secondderivative energy and pixel stability, the higher the energy, the lessstable the corresponding pixel.

In step 206, the CPU 12 outputs a list or lists of color (afterexecuting one or both of steps 202 and/or 204). According to a featureof the present invention, all of the further processing can be executedusing the list from either step 202 or 204, or vary the list used (oneor the other of the lists from steps 202 or 204) at each subsequentstep.

FIG. 7 is a flow chart for determining an orientation for a logchromaticity representation, according to a feature of the presentinvention. For example, the CPU 12 determines an orientation for thenormal N, for a log chromaticity plane, as shown in FIG. 5. In step 210,the CPU 12 receives a list of colors for an input file 18, such as alist output in step 206 of the routine of FIG. 6. In step 212, the CPU12 determines an orientation for a log chromaticity space.

As taught in U.S. Pat. No. 7,596,266, and as noted above, alignment ofthe chromaticity plane is represented by N, N being a vector normal tothe chromaticity representation, for example, the chromaticity plane ofFIG. 5. The orientation is estimated by the CPU 12 thorough execution ofany one of several techniques. For example, the CPU 12 can determineestimates based upon entropy minimization, manual selection by a user orthe use of a characteristic spectral ratio for an image of an inputimage file 18, as fully disclosed in U.S. Pat. No. 7,596,266.

For a higher dimensional set of colors, for example, an RYGB space (red,yellow, green, blue), the log chromaticity normal, N, defines asub-space with one less dimension than the input space. Thus, in thefour dimensional RYGB space, the normal N defines a three dimensionallog chromaticity space. When the four dimensional RYGB values areprojected into the three dimensional log chromaticity space, theprojected values within the log chromaticity space are unaffected byillumination variation.

In step 214, the CPU 12 outputs an orientation for the normal N. Asillustrated in the example of FIG. 5, the normal N defines anorientation for a u, v plane in a three dimensional RGB space.

FIG. 8 is a flow chart for determining log chromaticity coordinates forthe colors of an input image, as identified in steps 202 or 204 of theroutine of FIG. 6, according to a feature of the present invention. Instep 220, a list of colors is input to the CPU 12. The list of colorscan comprise either the list generated through execution of step 202 ofthe routine of FIG. 6, or the list generated through execution of step204. In step 222, the log chromaticity orientation for the normal, N,determined through execution of the routine of FIG. 7, is also input tothe CPU 12.

In step 224, the CPU 12 operates to calculate a log value for each colorin the list of colors and plots the log values in a three dimensionallog space at respective (log R, log G, log B) coordinates, asillustrated in FIG. 5. Materials A, B and C denote log values forspecific colors from the list of colors input to the CPU 12 in step 220.A log chromaticity plane is also calculated by the CPU 12, in the threedimensional log space, with u, v coordinates and an orientation set byN, input to the CPU 12 in step 222. Each u, v coordinate in the logchromaticity plane can also be designated by a corresponding (log R, logG, log B) coordinate in the three dimensional log space.

According to a feature of the present invention, the CPU 12 thenprojects the log values for the colors A, B and C onto the logchromaticity plane to determine a u, v log chromaticity coordinate foreach color. Each u, v log chromaticity coordinate can be expressed bythe corresponding (log R, log G, log B) coordinate in the threedimensional log space. The CPU 12 outputs a list of the log chromaticitycoordinates in step 226. The list cross-references each color to a u, vlog chromaticity coordinate and to the pixels (or a Type C tokens)having the respective color (depending upon the list of colors used inthe analysis (either step 202 (tokens) or 204 (pixels))).

FIG. 9 is a flow chart for optionally augmenting the log chromaticitycoordinates for pixels or Type C tokens with extra dimensions, accordingto a feature of the present invention. In step 230, the list of logchromaticity coordinates, determined for the colors of the input imagethrough execution of the routine of FIG. 8, is input to the CPU 12. Instep 232, the CPU 12 accesses the input image file 18, for use in theaugmentation.

In step 234, the CPU 12 optionally operates to augment each logchromaticity coordinate with a tone mapping intensity for eachcorresponding pixel (or Type C token). The tone mapping intensity isdetermined using any known tone mapping technique. An augmentation withtone mapping intensity information provides a basis for clusteringpixels or tokens that are grouped according to both similar logchromaticity coordinates and similar tone mapping intensities. Thisimproves the accuracy of a clustering step.

In step 236, the CPU 12 optionally operates to augment each logchromaticity coordinate with x, y coordinates for the correspondingpixel (or an average of the x, y coordinates for the constituent pixelsof a Type C token) (see FIG. 2 showing a P (1,1) to P (N, M) pixelarrangement). Thus, a clustering step with x, y coordinate informationwill provide groups in a spatially limited arrangement, when thatcharacteristic is desired.

In each of steps 234 and 236, the augmented information can, in eachcase, be weighted by a factor w₁ and w₂, w₃ respectively, to specify therelative importance and scale of the different dimensions in theaugmented coordinates. The weight factors w₁ and w₂, w₃ areuser-specified. Accordingly, the (log R, log G, log B) coordinates for apixel or Type C token is augmented to (log R, log G, log B, T*w₁, x*w₂,y*w₃) where T, x and y are the tone mapped intensity, the x coordinateand the y coordinate, respectively.

In step 238, the CPU 12 outputs a list of the augmented coordinates. Theaugmented log chromaticity coordinates provide accurate illuminationinvariant representations of the pixels, or for a specified regionalarrangement of an input image, such as, for example, Type C tokens.According to a feature of the present invention, the illuminationinvariant characteristic of the log chromaticity coordinates is reliedupon as a basis to identify regions of an image of a single material orreflectance, such as, for example, Type B tokens.

FIG. 10 is a flow chart for clustering the log chromaticity coordinates,according to a feature of the present invention. In step 240, the listof augmented log chromaticity coordinates is input the CPU 12. In step242, the CPU 12 operates to cluster the log chromaticity coordinates.The clustering step can be implemented via, for example, a known k-meansclustering. Any known clustering technique can be used to cluster thelog chromaticity coordinates to determine groups of similar logchromaticity coordinate values. The CPU 12 correlates each logchromaticity coordinate to the group to which the respective coordinatebelongs. The CPU 12 also operates to calculate a center for each groupidentified in the clustering step. For example, the CPU 12 can determinea center for each group relative to a (log R, log G, log B, log T)space.

In step 244, the CPU 12 outputs a list of the cluster group membershipsfor the log chromaticity coordinates (cross referenced to either thecorresponding pixels or Type C tokens) and/or a list of cluster groupcenters.

As noted above, in the execution of the clustering method, the CPU 12can use the list of colors from either the list generated throughexecution of step 202 of the routine of FIG. 6, or the list generatedthrough execution of step 204. In applying the identified cluster groupsto an input image, the CPU 12 can be operated to use the same set ofcolors as used in the clustering method (one of the list of colorscorresponding to step 202 or to the list of colors corresponding to step204), or apply a different set of colors (the other of the list ofcolors corresponding to step 202 or the list of colors corresponding tostep 204). If a different set of colors is used, the CPU 12 proceeds toexecute the routine of FIG. 11.

FIG. 11 is a flow chart for assigning the log chromaticity coordinatesto clusters determined through execution of the routine of FIG. 10, whena different list of colors is used after the identification of thecluster groups, according to a feature of the present invention. In step250, the CPU 12 once again executes the routine of FIG. 8, this time inrespect to the new list of colors. For example, if the list of colorsgenerated in step 202 (colors based upon Type C tokens) was used toidentify the cluster groups, and the CPU 12 then operates to classifylog chromaticity coordinates relative to cluster groups based upon thelist of colors generated in step 204 (colors based upon pixels), step250 of the routine of FIG. 11 is executed to determine the logchromaticity coordinates for the colors of the pixels in the input imagefile 18.

In step 252, the list of cluster centers is input to the CPU 12. In step254, the CPU 12 operates to classify each of the log chromaticitycoordinates identified in step 250, according to the nearest clustergroup center. In step 256, the CPU 12 outputs a list of the clustergroup memberships for the log chromaticity coordinates based upon thenew list of colors, with a cross reference to either correspondingpixels or Type C tokens, depending upon the list of colors used in step250 (the list of colors generated in step 202 or the list of colorsgenerated in step 204).

FIG. 12 is a flow chart for detecting regions of uniform reflectancebased on the log chromaticity clustering according to a feature of thepresent invention. In step 260, the input image file 18 is once againprovided to the CPU 12. In step 262, one of the pixels or Type C tokens,depending upon the list of colors used in step 250, is input to the CPU12. In step 264, the cluster membership information, form either steps244 or 256, is input to the CPU 12.

In step 266, the CPU 12 operates to merge each of the pixels, orspecified regions of an input image, such as, for example, Type Ctokens, having a same cluster group membership into a single region ofthe image to represent a region of uniform reflectance (Type B token).The CPU 12 performs such a merge operation for all of the pixels ortokens, as the case may be, for the input image file 18. In step 268,the CPU 12 outputs a list of all regions of uniform reflectance (andalso of similar tone mapping intensities and x, y coordinates, if thelog chromaticity coordinates were augmented in steps 234 and/or 236). Itshould be noted that each region of uniform reflectance (Type B token)determined according to the features of the present invention,potentially has significant illumination variation across the region.

U.S. Patent Publication No. US 2010/0142825 teaches a constraint/solvermodel for segregating illumination and material in an image, includingan optimized solution based upon a same material constraint. A samematerial constraint, as taught in U.S. Patent Publication No. US2010/0142825, utilizes Type C tokens and Type B tokens, as can bedetermined according to the teachings of the present invention. Theconstraining relationship is that all Type C tokens that are part of thesame Type B token are constrained to be of the same material. Thisconstraint enforces the definition of a Type B token, that is, aconnected image region comprising contiguous pixels that represent aregion of the image encompassing a single material in the scene, thoughnot necessarily the maximal region corresponding to that material. Thus,all Type C tokens that lie within the same Type B token are by thedefinition imposed upon Type B tokens, of the same material, though notnecessarily of the same illumination. The Type C tokens are thereforeconstrained to correspond to observed differences in appearance that arecaused by varying illumination.

Implementation of the constraint/solver model according to thetechniques and teachings of U.S. Patent Publication No. US 2010/0142825,utilizing the Type C tokens and Type B tokens obtained via a logchromaticity clustering technique according to the present invention,provides a highly effective and efficient method for generatingintrinsic images corresponding to an original input image. The intrinsicimages can be used to enhance the accuracy and efficiency of imageprocessing, image analysis and computer vision applications.

In the preceding specification, the invention has been described withreference to specific exemplary embodiments and examples thereof. Itwill, however, be evident that various modifications and changes may bemade thereto without departing from the broader spirit and scope of theinvention as set forth in the claims that follow. The specification anddrawings are accordingly to be regarded in an illustrative manner ratherthan a restrictive sense.

What is claimed is:
 1. An automated, computerized method for processingan image, comprising the steps of: providing an image file depicting animage, in a computer memory; determining illumination invariant logchromaticity representations for the image; clustering the logchromaticity representations to provide clusters of similar logchromaticity representations; and identifying regions of uniformreflectance in the image as a function of the clusters of similar logchromaticity representations, the regions of uniform reflectanceincluding illumination variation in the image across at least some ofthe regions of uniform reflectance.
 2. The method of claim 1 wherein thelog chromaticity representations for the image correspond to an array ofpixels representing the image.
 3. The method of claim 2 wherein the logchromaticity representations for the image are generated as a functionof the array of pixels representing the image.
 4. The method of claim 2comprising the further step of analyzing the array of pixelsrepresenting the image to identify tokens representing the image.
 5. Themethod of claim 4 wherein the log chromaticity representations for theimage are generated as a function of the tokens representing the image.6. The method of claim 1 comprising the further step of generatingintrinsic images as a function of the regions of uniform reflectance inthe image.
 7. The method of claim 1 wherein the log chromaticityrepresentations for the image are augmented.
 8. The method of claim 7wherein the log chromaticity representations for the image are augmentedwith tone mapping intensity information.
 9. The method of claim 8wherein the tone mapping information is weighted.
 10. The method ofclaim 7 wherein the log chromaticity representations for the image areaugmented with x, y coordinate information.
 11. The method of claim 10wherein the x, y coordinate information is weighted.
 12. A computersystem which comprises: a CPU; and a memory storing an image filecontaining an image; the CPU arranged and configured to execute aroutine to determine illumination invariant log chromaticityrepresentations for the image, cluster the log chromaticityrepresentations to provide clusters of similar log chromaticityrepresentations and identify regions of uniform reflectance in the imageas a function of the clusters of similar log chromaticityrepresentations, the regions of uniform reflectance includingillumination variation in the image across at least some of the regionsof uniform reflectance.
 13. The computer system of claim 12 wherein theCPU is further arranged and configured to execute a further routine togenerate intrinsic images as a function of the regions of uniformreflectance in the image.
 14. A computer program product, disposed on anon-transitory computer readable media, the product including computerexecutable process steps operable to control a computer to: provide animage file depicting an image, in a computer memory, determineillumination invariant log chromaticity representations for the image,cluster the log chromaticity representations to provide clusters ofsimilar log chromaticity representations and identify regions of uniformreflectance in the image as a function of the clusters of similar logchromaticity representations, the regions of uniform reflectanceincluding illumination variation in the image across at least some ofthe regions of uniform reflectance.
 15. The computer program product ofclaim 14 wherein the log chromaticity representations for the imagecorrespond to an array of pixels representing the image.
 16. Thecomputer program product of claim 15 wherein the log chromaticityrepresentations for the image are generated as a function of the arrayof pixels representing the image.
 17. The computer program product ofclaim 15 comprising the further process step of analyzing the array ofpixels representing the image to identify tokens representing the image.18. The computer program product of claim 17 wherein the logchromaticity representations for the image are generated as a functionof the tokens representing the image.
 19. The computer program productof claim 14 comprising the further process step of generating intrinsicimages as a function of the regions of uniform reflectance in the image.20. The computer program product of claim 14 wherein the logchromaticity representations for the image are augmented.
 21. Thecomputer program product of claim 20 wherein the log chromaticityrepresentations for the image are augmented with tone mapping intensityinformation.
 22. The computer program product of claim 21 wherein thetone mapping information is weighted.
 23. The computer program productof claim 20 wherein the log chromaticity representations for the imageare augmented with x, y coordinate information.
 24. The computer programproduct of claim 23 wherein the x, y coordinate information is weighted.25. The method of claim 4 wherein each step of the method is executed asa function of a list of colors for the image, the list of colors used ineach step being identified as a function of one of the array of pixelsof the image and tokens representing the image.
 26. The computer programproduct of claim 17 wherein each process step is executed as a functionof a list of colors for the image, the list of colors used in eachprocess step being identified as a function of one of the array ofpixels of the image and tokens representing the image.